<template>
  <div>
    <h1>我是About组件</h1>
  </div>
</template>

<script>
export default {
  name: 'MyAbout',
  beforeRouteEnter(to, from, next) {
    if(to.meta.isAuth) {
      if(localStorage.getItem('auth') === 'lqj') {
        next()
      }else {
        alert('未经lqj允许，无法访问该页面内容')
      }
    }else {
      next()
    }
  },
  beforeRouteLeave(to, from, next) {
    next()
  }
}
</script>